<template>
     <el-dialog v-model="dialogShow" title="删除文章" width="460px" close-on-click-modal="false" :before-close="clickOff">
      <el-form :model="form" ref="submitForm" label-width="auto" :rules="rules">

           <el-form-item label="是否删除该文章：" prop="shi4fou3shan1chu2gai1wen2zhang1">
               <el-radio-group v-model="form.shi4fou3shan1chu2gai1wen2zhang1" class="ml-4">
                 <el-radio v-for="(item,index) in shi4fou3shan1chu2gai1wen2zhang1arr" :key="index" :label="item.articleId" size="large">{{ item.已删除 }}</el-radio>
               </el-radio-group>
           </el-form-item>

        </el-form>
        <template #footer>
                    <span class="dialog-footer">
                        <el-button @click="clickOff(); ; form = [{}]">取消</el-button>
                        <el-button type="primary" @click="submit()">确定</el-button>
                    </span>
        </template>
        </el-dialog>



</template>
<script>
    
export default {
    data() {
        return {
            id: this.$route.params.id,
            shi4fou3shan1chu2gai1wen2zhang1arr:[],
            dialogShow: true,
            id: '',
            loading: false,
            form: {}, content: '',
            classificationL: [],
            param: {},
            uploadUrl: `/api/system/upload/uploadList`,
        }
    },

    created() {
         this.getshi4fou3shan1chu2gai1wen2zhang1();
    },

    mounted() {
    },

    components: {
    },

    methods: {
          getshi4fou3shan1chu2gai1wen2zhang1(){
            let that = this
             that.$api.deletearticle().then(res=>{
                 that.shi4fou3shan1chu2gai1wen2zhang1arr = res
             })
          },



        clickOff(){
           this.$parent.dialogShow386 = false;
           this.dialogShow = false;
        },



        submit() {
            console.log(this.form, 'this.form=============')
            let that = this;
            that.$parent.dialogShow = false
            that.$refs['submitForm'].validate((val) => {
                if (val) {
                    let form = JSON.parse(JSON.stringify(that.form))
                        that.$api.deletearticle(form).then(res => {
                    that.fullscreenLoading = false;
                    console.log(res);
                    if (res) {
                        that.$message.success(res.message);
                        this.$parent.dialogShow1 = false;
                        this.dialogShow = true;
                    }
                    });
                }
            })
        },



    }

}


</script>
<style lang="scss" scoped>

.div1{
    background-color: #fff;
    padding: 25px;
    box-sizing: border-box;
}
.buttons1{
    width: 100%;
    display: flex;
    justify-content: center;
    .buttons1_button1{
        width: 200px;
        height: 50px;
    }
}
.dialog1_title1 {
    display: inline-block;
    font-size: 12px;
    color: #9e9e9e;
    width: 100%;
}

.dialog1_prompt1 {
    display: inline-block;
    color: #9e9e9e;
    line-height: 20px;
    padding-top: 10px;
    font-size: 12px;
    text-align: left;
    width: 100%;
}

.dialog1_prompt2 {
    display: inline-block;
    color: #9e9e9e;
    line-height: 20px;
    padding-top: 10px;
    font-size: 12px;
    text-align: left;
    width: 100%;
}

.dialog1_video1 {
    width: 500px;
}

.dialog1_img1 {
    width: 300px;
}

.dialog1_img2 {
    width: 100px;
    height: 100px;
    margin-right: 20px;
}

</style>